home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 464 < prev    next >
Encoding:
Text File  |  1996-08-05  |  996 b   |  37 lines

  1. Newsgroups: comp.lang.c++
  2. Path: news3.noc.netcom.net!zdc!zippo!usenet
  3. From: Jim McFarland <jgm6@orkand.em.cdc.gov>
  4. Subject: Re: C to C++
  5. Content-Type: text/plain; charset=us-ascii
  6. Sender: usenet@news.zippo.com
  7. Content-Transfer-Encoding: 7bit
  8. Nntp-Posting-Host: 158.111.166.77
  9. Organization: The Orkand Corporation
  10. Message-ID: <DKnxBv.Gnq@news.zippo.com>
  11. References: <30EA2EA0.86C@comcept.ab.ca>
  12. X-Mailer: Mozilla 1.1N (Windows; I; 16bit)
  13. Mime-Version: 1.0
  14. Date: Thu, 4 Jan 1996 15:21:31 GMT
  15.  
  16. The BFP <bfp@comcept.ab.ca> wrote:
  17. >Hey,
  18. >
  19. >I am new at this stuff, and I am trying to learn C++.  I have looked at C 
  20. >source code, and incredibly Simple programs like
  21. >
  22. ><#include stdio.h>
  23. >
  24. >printf("Hi")
  25. >
  26. >Will not compile for C++.  I am lame, yes, I kn ow but, hey, Nobody is 
  27. >perfect, anyways, could somebody help me :)
  28. >
  29. >Please :)
  30.  
  31. First of all, this "program" would NOT compile in C either.  You have no 
  32. main() function.  If you put the printf() in main(), it would compile as 
  33. C or C++.
  34.  
  35. Jim
  36.  
  37.